Repository navigation
images: check Fedora package signatures in the image build - #135
Merged
Merged
Conversation
The pinned KIWI description declares Fedora's fedora and updates repositories with a <signing> key but no package_gpgcheck. KIWI's dnf5 backend (kiwi 11.1.1) then writes gpgcheck=0 into their repo files, which overrides the gpgcheck=1 that <rpm-check-signatures> sets in [main]. On main, a Minimal `kiwi-ng system prepare` in a fedora:44 container with the Fedora key swapped for Fedora 43's still succeeds, and dnf5 says so: Warning: skipped OpenPGP checks for 184 packages from repositories: fedora, updates Warning: skipped OpenPGP checks for 626 packages from repositories: fedora, updates configure.py now sets package_gpgcheck on every upstream repository and refuses one without a signing key. KIWI imports the <signing> keys into the image rpm database before the first package, so dnf5 checks every Fedora package against the description's key, /usr/share/distribution-gpg-keys/fedora/RPM-GPG-KEY-fedora-44-primary. That file has the same bytes as fedora-gpg-keys' copy (fingerprint 36F612DCF27F7D1A48A835E4DBFCF71C6D9F90A6), and its path does not move between host releases, while Fedora 45's fedora-gpg-keys keeps its keys under /usr/share/pki/rpm-gpg instead of /etc/pki/rpm-gpg. images.yml already installs distribution-gpg-keys. The same prepare with this change: - correct key: succeeds with no skipped checks; the root holds 866 packages, 810 of them signed by the Fedora 44 key. - Fedora 43's key: stops at bootstrap with "Signature verification failed" for filesystem-3.18-52.fc44 from repo "fedora". Assisted-by: Claude Opus 5.5
RyanTheTide
added a commit
that referenced
this pull request
Nov 9, 2026
…134, #133) RC8.2 = RC8.1 + speakerguardd#134: a switch in the running boot grants at once (aurora-speaker-upgrade's umask 077 leaked into v2's provisioning, so /run/speakerguardd-graph was unreadable to the seat user and the speakers stayed silent until a reboot; found by the RC8 E2E on the M1 Pro and M2), #133 (the MacBook Neo's speaker PCM wakes on period interrupts), and voicing parity #129/#135. aurora-speaker-upgrade rides on the same commit. Signed-off-by: Ryan Murray <81541646+RyanTheTide@users.noreply.github.com> Assisted-by: LLM
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Image builds now check the signature of every Fedora package, not only Aurora's.
Problem
The pinned KIWI description (
repositories/core.xml) declares Fedora'sfedoraandupdatesrepositories with a<signing>key but nopackage_gpgcheck. KIWI 11.1.1's dnf5 backend (add_repo(..., pkg_gpgcheck=False)) then writesgpgcheck=0into each repository file. That overrides thegpgcheck=1that<rpm-check-signatures>puts in[main]. PR #134 fixed this for the Aurora repository only.Change
images/configure.pysetspackage_gpgcheck="true"on every upstream repository and refuses one without a<signing>key ("review the integration", like the other upstream checks). KIWI already imports<signing>keys into the image rpm database before the first package.The key stays the description's
file:///usr/share/distribution-gpg-keys/fedora/RPM-GPG-KEY-fedora-$releasever-primary. It is byte-identical tofedora-gpg-keys' copy: same sha256, fingerprint36F612DCF27F7D1A48A835E4DBFCF71C6D9F90A6. Its path also stays put across build-host releases. Fedora 45'sfedora-gpg-keyskeeps its keys under/usr/share/pki/rpm-gpgand no longer has/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-44-primary.images.ymlalready installsdistribution-gpg-keys. The image itself still importsfedora-gpg-keys' key in upstream'sconfig.sh.Evidence
kiwi-ng --type oem --profile Minimal --target-arch=aarch64 system prepareran in afedora:44aarch64 container (kiwi 11.1.1, dnf5 5.4.6) against the live testing feed. To prove the check is enforced, one run swapped the Fedora key for Fedora 43's.skipped OpenPGP checks for 184 packages from repositories: fedora, updates(bootstrap), then… 626 packages …(system)Signature verification failed,OpenPGP check for package "filesystem-3.18-52.fc44.aarch64" … from repo "fedora" has failedconfig.shran in the successful runs, so the image checks passed too. The full image build (disk, finalizer,check-basics.py) isimages.yml, which I have not dispatched.Checks job steps on Linux (
fedora:44):unittest discover -s tests(249, OK),images/test_configure.py(17, OK; the new test fails on main'sconfigure.py),compileall,bash -n,git diff --check.No package changes, so no spec bump.
🤖 Generated with Claude Code